package com.ch.design.kingdom;

/**
 * 内部类
 * @author CH
 * @date 2022/2/22
 */
public class King03 {
    private String name = "国王";

    private static class KingSmall{
        private static King03 king = new King03();
    }

    private King03(){}

    public static King03 getKing(){
        return KingSmall.king;
    }
}
